1. Field of the Invention
The present invention relates to an image processing apparatus and image processing method for segmenting an input image into regions, assigning attribute information to the segmented regions, and generating print data based on the attribute information.
2. Description of the Related Art
There has conventionally been proposed a method of clustering illustration regions (clip art regions) in an original image by color, and vectorizing them (see, e.g., Japanese Patent Laid-Open No. 2007-109177). The illustration region is a region where the contour of an object is clearer than a natural image such as a photograph, and the number of colors in it is limited.
However, the image quality becomes poor when vector data is generated from an illustration region and printed. For example, even when the color inside an illustration region and the color around it are originally the same, they are printed in different tints. This is because the illustration region has a graphic attribute, its peripheral region has an image attribute, and different color processes and image forming processes are executed in accordance with these pieces of attribute information. Image processing (e.g., color processing and image forming processing) suitable for graphics and that suitable for images are different. Thus, a region with a graphic attribute and one with an image attribute undergo different image processes. As a result, these regions seem to have different tints.
There is also proposed a method of preventing the phenomenon in which even pixel regions having the same color data are printed in different tints (see, e.g., Japanese Patent Laid-Open No. 2006-157791).
According to this method, a bitmap image and attribute information of each pixel are created based on a rendering command. The similarity of color data between a pixel of interest and the remaining pixels is determined. Then, attribute change processing is done for each pixel.
However, when generating vector data from an illustration region and printing it, even if the color inside an illustration region and the color around it are originally the same, these colors are printed in different tints. If the method as disclosed in Japanese Patent Laid-Open No. 2006-157791 is applied to this problem, the following problems arise.
First, the processing load is high because attribute change processing needs to be performed for each pixel. Second, it is difficult to convert bitmap data into a PDL format.